<?php
include_once ("../Login/databaseconnection.php");

 $Pro_Id=$_POST['Pro_Id'];
 $Pro_name=$_POST['Pro_name'];
 date_default_timezone_set("Europe/Paris");
    $t_d=date("Y/m/d");
  if($Pro_Id!=""&&$Pro_name!="")
	{
$sql=mysql_query("INSERT INTO programme(Programme_Id,Programme_Name,Last_Updated_Date)values('$Pro_Id','$Pro_name','$t_d')");
if(mysql_affected_rows()==1)
  {
$_SESSION['error']="This record is successfully registered!";
$_SESSION['OK']="OK";
$_SESSION['Pro_Id']=$Pro_Id;
  }

  if(mysql_affected_rows()==0)
  {
$_SESSION['error']="Sorry unable to register this record!";
  }
  }
 if($Pro_Id==""||$Pro_name=="")
	{
	$_SESSION['errorin']="Please fill all!";
  }
?>
